<template>
	<div class="WdGrid">
		<van-grid :column-num="style.gridProps.columnNum" :gutter="style.gridProps.gutter"
			:border="style.gridProps.border">
			<!--      {text: '商城', icon: '', url: '',iconColor: '', linkType: '', useSlot: false, slotImageSrc: 'https://img.yzcdn.cn/vant/apple-1.jpg' }-->
			<van-grid-item :key="index" :icon="item.icon" :icon-color="item.iconColor" :text="item.text"
				:linkType="item.linkType" :useSlot="item.useSlot" v-for="(item, index) in style.gridItemProps">
				<template #icon>
					<div
						:style="'font-size: ' + style.gridProps.iconSize + 'px;' + (item.iconColor.length > 0?'color:' + item.iconColor : '') ">
						<i :class="item.icon"></i>
						<van-icon :name="item.icon"></van-icon>
					</div>
				</template>
			</van-grid-item>
		</van-grid>

	</div>
</template>

<script>
	export default {
		name: 'WdGrid',
		props: {
			datas: Object,
		},


		data() {
			return {
				style: this.datas.setStyle

			}
		},
		created() {},

		methods: {},
	}
</script>

<style scoped lang="scss">
	.WdGrid {
		position: relative;
	}
</style>